<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:c="http://java.sun.com/jsp/jstl/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:p="http://primefaces.org/ui">

	<ui:composition template="WEB-INF/templates/principal/principal.xhtml">
		<ui:define name="content">
			<div id="login">			
				<p:messages id="messages" 
			    showDetail="true" 
			    autoUpdate="true"
				showSummary="false" />	
				<p:panel header="Login">
					<h:form id="formLogin">
						<h:panelGrid columns="2" cellpadding="5">
							<h:outputLabel value="E-mail" />
							<p:inputText value="#{loginManagedBean.email}" id="email" required="true" requiredMessage="E-mail deve ser informado">
							</p:inputText>
							<h:outputLabel value="Senha"/>
							<p:password feedback="false" value="#{loginManagedBean.senha}" id="senha" required="true" requiredMessage="Senha deve ser informado">
							</p:password>
							<p:commandButton value="Enviar" actionListener="#{loginManagedBean.login}"/>
						</h:panelGrid>
					</h:form>
				</p:panel>				
			</div>
		</ui:define>
	</ui:composition>
</html>